
    <link rel="stylesheet" href="<?php echo $this->baseUrl; ?>/css/demo_page.css" type="text/css" />
    <link rel="stylesheet" href="<?php echo $this->baseUrl; ?>/css/demo_table_jui.css" type="text/css" />
    <link rel="stylesheet" href="<?php echo $this->baseUrl; ?>/css/jquery-ui-1.8.4.custom.css" type="text/css" />
    <link rel="stylesheet" href="<?php echo $this->baseUrl; ?>/css/TableTools_JUI.css" type="text/css" />

    <script type="text/javascript" src="<?php echo $this->baseUrl(); ?>/js/jquery.js"></script>
    <script type="text/javascript" src="<?php echo $this->baseUrl(); ?>/js/jquery.dataTables.js"></script>
    <script type="text/javascript" src="<?php echo $this->baseUrl(); ?>/js/jquery-ui-tabs.js"></script>
    <script type="text/javascript" src="<?php echo $this->baseUrl(); ?>/js/ZeroClipboard.js"></script>
    <script type="text/javascript" src="<?php echo $this->baseUrl(); ?>/js/TableTools.js"></script>
    
    <script type="text/javascript" charset="utf-8">
        $(document).ready(function() {
            $("#tabs").tabs( {
                "show": function(event, ui) {
                    var jqTable = $('table.display', ui.panel);
                    if ( jqTable.length > 0 ) {
                        var oTableTools = TableTools.fnGetInstance( jqTable[0] );
                        if ( oTableTools != null && oTableTools.fnResizeRequired() )
                        {
                            jqTable.dataTable().fnAdjustColumnSizing();
                            oTableTools.fnResizeButtons();
                        }
                    }
                }
            } );

            $('#example1').dataTable( {
                    "bJQueryUI": true,
                    "sPaginationType": "full_numbers",
                    "sDom": '<"H"Tfr>t<"F"ip>'
            } );
        } );
    </script>

    
    
    
    
    
    
        
<body id="dt_example">   
    <div id="container">


        <div id="demo">      

<table cellpadding="0" cellspacing="0" border="0" class="display" id="example1">
    <thead>
        <tr>
            <th>ID</th>
            <th>Cedula</th>
            <th>Nombre</th>
            <th>Total_Deuda_Pagada</th>
            <th>Total_Deuda_Faltante</th>
            <th>Cantidad_Pendiente</th>
            <th>Pagar?</th>
            <th>Eliminar?</th>
        </tr>
    </thead>
    <tfoot>
        <tr>
            <th>ID</th>
            <th>Cedula</th>
            <th>Nombre</th>
            <th>Total_Deuda_Pagada</th>
            <th>Total_Deuda_Faltante</th>
            <th>Cantidad_Pendiente</th>
            <th>Pagar?</th>
            <th>Eliminar?</th>
        </tr>
    </tfoot>
<tbody>
    <?php foreach ($this->datos as $d) : ?>
        <tr class="odd_gradeX">
        <td class="center"><?php echo $this->escape($d->id); ?></td>

        <td class="center"><?php echo $this->escape($d->cedula); ?></td>
        <td class="center"><?php echo $this->escape($d->nombre . ' ' . $d->apellido); ?></td>
        
        <th class="center"><?php echo $this->escape($d->total); ?></th>
        <th class="center"><?php echo $this->escape($d->totalDeuda); ?></th>
        <th class="center"><?php echo $this->escape($d->cantidad); ?></th>

        <td class="center">
            <a href="<?php echo $this->url(array('controller' => 'pagos',
            'action' => 'agregar', 'id' => $d->id)); ?>">Pagar</a>
        </td>
        <td class="center">
         <a href="<?php echo $this->url(array('controller' => 'pagos',
            'action' => 'eliminar', 'id' => $d->id)); ?>" onclick='if (confirm("Estas Seguro de Eliminar?")) { document.form.submit(); } return false;'>Eliminar</a>
        </td>
       
        </tr>
    <?php endforeach; ?>

</tbody>

</table>

</div> 
        
    <div class="spacer"></div>
			

    </div>
</body>
